﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Runtime.CompilerServices;
using System.Text;
using System.Threading.Tasks;

namespace _06_01NortifyPropertyChanged通知更新
{
	public class MyPropertyChanged : INotifyPropertyChanged
	{
		//这个通知更改写成基类，让属性去继承，直接调用，不用在每个属性上写
		public event PropertyChangedEventHandler? PropertyChanged;

		public void Changed([CallerMemberName]string Property="")
		{
			PropertyChanged?.Invoke(this,new PropertyChangedEventArgs(Property));
		}
	}
}
